<?php

$TCA['reality'] = array(
	'ctrl' => $TCA['reality']['ctrl'],
	'interface' => array(
		'showRecordFieldList' => 'pid,hidden,title,alias,short_description,rooms,main_image,bodytext,street,fk_city_id,price,area,properties,google_map,fk_agent_id,images,view_count'
	),
	'types' => array(
		'1' => array('showitem' => 'pid,hidden,title,alias,short_description,rooms,main_image,bodytext;;;richtext[paste|bold|italic|underline|formatblock|class|left|center|right|orderedlist|unorderedlist|outdent|indent|link|image]:rte_transform[mode=ts],street,fk_city_id,price,area,properties,google_map,fk_agent_id,images,view_count')
	),
	'palettes' => array(
		'1' => array('showitem' => '')
	),
	'columns' => array(
		'hidden' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.hidden',
			'config'  => array(
				'type' => 'check',
			),
		),
		'title' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.title',
			'config'  => array(
				'type' => 'input',
				'size' => 128,
				'eval' => 'trim,required',
			),
		),
		'alias' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.alias',
			'config'  => array(
				'type' => 'input',
				'size' => 128,
				'eval' => 'trim,required',
			),
		),
		'short_description' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.short_description',
			'config'  => array(
				'type' => 'text',
				'cols' => '30',
				'rows' => '5',
			)
		),
		'rooms' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.rooms',
			'config'  => array(
				'type' => 'input',
				'size' => 12,
				'eval' => 'trim',
			),
		),
		'main_image' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.main_image',
			'config'  => array(
				'type'          => 'group',
				'internal_type' => 'file',
				'allowed'       => 'jpg,png,gif,jpeg',
				'max_size'      => 30000,
				'uploadfolder'  => 'uploads/tx_reality/reality/',
				'show_thumbs'   => 0,
				'size'          => 1,
				'minitems'      => 0,
				'maxitems'      => 1,
			),
		),
		'bodytext' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.bodytext',
			'config'  => array(
				'type' => 'text',
				'cols' => '30',
				'rows' => '5',
				'wizards' => Array(
					'_PADDING' => 2,
					'RTE' => array(
						'notNewRecords' => 1,
						'RTEonly' => 1,
						'type' => 'script',
						'title' => 'Full screen Rich Text Editing|Formatteret redigering i hele vinduet',
						'icon' => 'wizard_rte2.gif',
						'script' => 'wizard_rte.php',
					),
				),
			)
		),
		'street' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.street',
			'config'  => array(
				'type' => 'input',
				'size' => 128,
				'eval' => 'trim',
			),
		),
		'fk_city_id' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.city',
			'config'  => array(
				'type' => 'select',
				'foreign_table' => 'city',
				'foreign_table_where' => ' ORDER BY city.title ASC',
				'items' => array(array(0 => '')),
				'minitems' => 1,
				'maxitems' => 1,
			),
		),
		'price' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.price',
			'config'  => array(
				'type' => 'input',
				'size' => 12,
				'eval' => 'trim,integer',
			),
		),
		'area' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.area',
			'config'  => array(
				'type' => 'input',
				'size' => 12,
				'eval' => 'trim,integer',
			),
		),
		'fk_agent_id' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.agent',
			'config'  => array(
				'type' => 'select',
				'foreign_table' => 'agent',
				'foreign_table_where' => ' ORDER BY agent.name ASC',
				'items' => array(array(0 => '')),
				'minitems' => 1,
				'maxitems' => 1,
			),
		),
		'google_map' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.google_map',
			'config'  => array(
				'type' => 'text',
				'cols' => '30',
				'rows' => '5',
			)
		),
		'properties' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.properties',
			'config'  => array(
				'type' => 'select',
				'size' => 10,
				'minitems' => 0,
				'maxitems' => 50,
				'multiple' => 1,
				'foreign_table' => 'property',
				'foreign_table_where' => ' ORDER BY property.title ASC',
				'MM' => 'reality_property',
			)
		),
		'images' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.images',
			'config'  => array(
				'type' => 'inline',
				'internal_type' => 'db',
				'allowed' => 'image',
				'foreign_table' => 'image',
				'MM' => 'reality_image',
				'minitems' => 0,
				'maxitems' => 99,
				'size' => 5,
				'wizards' => array(
					'suggest' => array(
						'type' => 'suggest',
					),
				),
			),
		),
		'view_count' => array(
			'exclude' => 0,
			'label'   => 'LLL:EXT:reality/Resources/Private/Language/locallang_db_reality.xml:reality.view_count',
			'config'  => array(
				'type' => 'none',
				'size' => 12,
			),
		),
	),
);

?>